package com.wish.g01.contract.sign;

import com.itextpdf.kernel.pdf.PdfDictionary;
import com.itextpdf.signatures.IExternalSignatureContainer;

import java.io.InputStream;
import java.security.GeneralSecurityException;

/**
 * @author Ethan
 * @version 1.0
 * @description: TODO
 * @date 2021/6/24 0024
 */
public class EmbdedSignatureContainer implements IExternalSignatureContainer{
    byte[] signature;
    public EmbdedSignatureContainer(byte[] pkcs7Signature) {
        this.signature = pkcs7Signature;
    }
    @Override
    public byte[] sign(InputStream is) throws GeneralSecurityException {
        return signature;
    }
    @Override
    public void modifySigningDictionary(PdfDictionary signDic) {
    }
}